﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace XqWebSite
{
    public partial class WebForm22 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            {
                if (!IsPostBack)//判断是否回发
                {

                }
            }
        }

        protected void But_tj_Click(object sender, EventArgs e)
        {//次处应为update根据公告ID进行对应
            string SQL = "";
            bool iRet = false;
            string id = Tex_ggid.Text;
            SQL = "update TongZhiGongGao set ZhuhuID ='" + Tex_yhid.Text + "',LiuYanNeiRong ='" + Tex_nr.Text + "',LiuYanShiJian = '" + Tex_time.Text
                  + "' where ID='" + id + "'";//执行更新操作
            iRet = DBHelper.ExecSql(SQL);


            if (iRet)
            {
                DBHelper.ShowMessage(Page, "恭喜您，操作成功！", "");
                Tex_yhid.Text = "";
                Tex_nr.Text = "";
                Tex_time.Text = "";
                //Response.Redirect("XunluojieguoFk.aspx");
            }
            else
            {
                DBHelper.ShowMessage(Page, "对不起，操作失败！", "");
            }
        }

        protected void But_qx_Click(object sender, EventArgs e)
        {
           
            Response.Redirect("ZhChakangonggaoxinxi.aspx");
        }
    }
}